package com.xx.mapper;

import com.xx.entity.Categories;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.xx.entity.CategoriesList;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;


@Mapper
public interface CategoriesMapper extends BaseMapper<Categories> {

    Categories queryById(Integer categoryId);

    List<Categories> queryAllByLimit(Categories categories);

    long count(Categories categories);

    int insert(Categories categories);

    int insertBatch(@Param("entities") List<Categories> entities);

    int insertOrUpdateBatch(@Param("entities") List<Categories> entities);

    int update(Categories categories);

    int deleteById(Integer categoryId);

    List<CategoriesList> list();
}
